package com.szq.pattern;

/**
 * @description:
 * @author: szq
 * @date: 2021-09-02 16:19:02
 */
public class ProductFactory {

    public static IProduct getProduct(String name){
        if ("a".equals(name)){
            return new ProductAImpl();
        }
        return new ProductBImpl();
    }
}
